<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <script src="js/vue.js"></script>
</head>
<body>
  <div id="app">
    <h3>遍历数组中每个元素</h3>
    <ul>
      <li>1 - 亮亮</li>
      <li>2 - 然然</li>
      <li>3 - 东东</li>
    </ul>
    <h3>遍历对象中每个属性</h3>
    <ul>
      <li>sname - Li Lei</li>
      <li>sage - 11</li>
      <li>class - 初一2班</li>
    </ul>
  </div>
  <script>
    var vm=new Vue({
      el:"#app",
      data:{
        arr:["亮亮","然然","东东"],
        lilei:{
          sname:"Li Lei",
          sage:11,
          class:"初一2班"
        }
      }
    })
    //比较: 
    //vm.arr[1]="小月月"，能否修改数组，能否更新界面？
    //vm.arr.splice(1,1,"小月月")，能否修改数组，能否更新界面？
  </script>
</body>
</html>